import { ColumnType } from "antd/es/table"
import Link from "antd/es/typography/Link"

import { useDigital } from "@/hooks"
import { useLocale } from "@/locales"
export const columnsClubContributeInfo = () => {
	const { formatMessage } = useLocale()
	const { renderColor, renderFormatWithCurrency } = useDigital()
	return [
		{
			dataIndex: "clubId",
			title: formatMessage({ id: "member.club_table.clubId" }),
			render: (value: any, record: any) => (
				<Link href={`/dxn/clubManager/clubList?clubId=${record.clubId}`}>{record.clubId}</Link>
			),
			width: 150,
			align: "center",
			key: "clubId"
		},
		{
			dataIndex: "clubName ",
			title: formatMessage({ id: "member.club_table.clubName" }),
			render: (value: any, record: any) => <p>{record.clubName || "-"}</p>,
			width: 150,
			align: "center",
			key: "clubName"
		},
		{
			dataIndex: "handCount",
			title: formatMessage({ id: "member.club_table.handCount" }),
			render: (value: any, record: any) => <p>{record.handCount + "" || "-"}</p>,
			width: 150,
			align: "center",
			key: "handCount"
		},
		{
			dataIndex: "validBetAmount",
			title: formatMessage({ id: "member.club_table.validBetAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.validBetAmount)}</p>,
			width: 150,
			align: "center",
			key: "validBetAmount"
		},
		{
			dataIndex: "insuranceValidBetAmount",
			title: formatMessage({ id: "member.club_table.insuranceValidBetAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.insuranceValidBetAmount)}</p>,
			width: 150,
			align: "center",
			key: "insuranceValidBetAmount"
		},
		{
			dataIndex: "evInsuranceValidBetAmount",
			title: formatMessage({ id: "member.club_table.evInsuranceValidBetAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.evInsuredValidBetAmount)}</p>,
			width: 150,
			align: "center",
			key: "evInsuranceValidBetAmount"
		},
		{
			dataIndex: "netAmount",
			title: formatMessage({ id: "member.club_table.netAmount" }),
			render: (value: any, record: any) => <p>{renderColor(record.netAmount)}</p>,
			width: 150,
			align: "center",
			key: "netAmount"
		},
		{
			dataIndex: "insuranceNetAmount",
			title: formatMessage({ id: "member.club_table.insuranceNetAmount" }),
			render: (value: any, record: any) => {
				return <p>{renderColor(record.insuranceNetAmount)}</p>
			},
			width: 150,
			align: "center",
			key: "insuranceNetAmount"
		},
		{
			dataIndex: "evInsuredNetAmount",
			title: formatMessage({ id: "member.club_table.evInsuredNetAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.evInsuredNetAmount)}</p>,

			width: 150,
			align: "center",
			key: "evInsuredNetAmount"
		},
		{
			dataIndex: "squidNetAmount",
			title: formatMessage({ id: "member.club_table.squidNetAmount" }),
			width: 150,
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.squidNetAmount)}</p>,

			align: "center",
			key: "squidNetAmount"
		},
		{
			dataIndex: "sendBarrageAmount",
			title: formatMessage({ id: "member.club_table.sendBarrageAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.sendBarrageAmount)}</p>,

			width: 150,
			align: "center",
			key: "sendBarrageAmount"
		},
		{
			dataIndex: "sendEmoteAmount",
			title: formatMessage({ id: "member.club_table.sendEmoteAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.sendEmoteAmount)}</p>,

			width: 150,
			align: "center",
			key: "sendEmoteAmount"
		},
		{
			dataIndex: "sendPuraseAmount",
			title: formatMessage({ id: "member.club_table.sendPuraseAmount" }),
			width: 150,
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.sendPuraseAmount)}</p>,

			align: "center",
			key: "sendPuraseAmount"
		},
		{
			dataIndex: "sendVoiceAmount",
			title: formatMessage({ id: "member.club_table.sendVoiceAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.sendVoiceAmount)}</p>,

			width: 150,
			align: "center",
			key: "sendVoiceAmount"
		},
		{
			dataIndex: "interactPropAmount",
			title: formatMessage({ id: "member.club_table.interactPropAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.interactPropAmount)}</p>,

			width: 150,
			align: "center",
			key: "interactPropAmount"
		},
		{
			dataIndex: "lookPublicCardAmount",
			title: formatMessage({ id: "member.club_table.lookPublicCardAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.lookPublicCardAmount)}</p>,

			width: 150,
			align: "center",
			key: "lookPublicCardAmount"
		},
		{
			dataIndex: "betActionDelayAmount",
			title: formatMessage({ id: "member.club_table.betActionDelayAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.betActionDelayAmount)}</p>,

			width: 150,
			align: "center",
			key: "betActionDelayAmount"
		},
		{
			dataIndex: "insureActionDelayAmount",
			title: formatMessage({ id: "member.club_table.insureActionDelayAmount" }),
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.insureActionDelayAmount)}</p>,

			width: 150,
			align: "center",
			key: "insureActionDelayAmount"
		},
		{
			dataIndex: "pumpContribution",
			title: formatMessage({ id: "member.club_table.pumpContribution" }),
			width: 150,
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.pumpContribution)}</p>,

			align: "center",
			key: "pumpContribution"
		},
		{
			dataIndex: "tableFeeContribution",
			title: formatMessage({ id: "member.club_table.tableFeeContribution" }),
			width: 150,
			render: (value: any, record: any) => <p>{renderFormatWithCurrency(record.tableFeeContribution)}</p>,

			align: "center",
			key: "tableFeeContribution"
		}
	] as ColumnType<any>[]
}
